<?php

// This Class is for you. 
// Feel free to edit this file to extend your models classes.
// Please, never touch sufixed _protoweb classes

/**
 * 
 *
 * @Authors Sánchez Raúl * @package cliente
 * @subpackage model
 */
class Usuario extends Usuario_protoweb
{

	public function __construct($id = NULL) 
	{
		parent::__construct($id);
	}

	public function login() {
    $this->where('username', $this->username);
    $this->where('password', $this->password)->get();

    if ($this->exists())
      return TRUE;
    else {
      $this->error_message('login', 'Datos de login inválidos');
      return FALSE;
    }
  }

} // Class usuario

/* End of file usuario.php */
/* Location: ./application/models/usuario.php */